package com.example.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.example.dto.CategoryDTO;
import com.example.pojo.Category;
import com.example.pojo.PageBean;

public interface CategoryService extends IService<Category> {

    //根据名称查询对应类别是否存在
    public Category findByName(String name);

    //新增图书时同时更新类别表
    public void updateByName(String name, Integer newSum);

    //删除类别
    public void deleteByName(String name);

    //分页查询
    public PageBean<Category> find(CategoryDTO categoryDTO);
}
